package com.mg.order.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.mg.common.pojo.auto.generate.Stock;
import com.mg.order.pojo.dto.StockDto;
import com.mg.order.pojo.po.StockPo;
import org.apache.ibatis.annotations.Param;

public interface StockMapper extends BaseMapper<StockPo> {
    int deleteByPrimaryKey(Long skuId);

    int insert(Stock record);

    int insertSelective(Stock record);

    Stock selectByPrimaryKey(Long skuId);

    int updateByPrimaryKeySelective(Stock record);

    int updateByPrimaryKey(Stock record);

    int stockSell(@Param("num")Integer num,@Param("skuId")Long skuId);
}